package com.example.demo.day.config.learn.design.adapter.p3;

//客户端代码
public class MotorAdapter {

    public static void main(String[] args) {
        System.out.println("适配器模式");
        Motor motor = new ElectricAdapter();
        motor.drive();
        motor = new OpticalAdapter();
        motor.drive();
    }


}
